<template>
  <div>
    <router-view></router-view>
  </div>
</template>

<script>
import projectConfig from '@/core/config';
import { MP } from './assets/js/map';

export default {
  data () {
    return {
      ak: 'ZM6fZihEjR1YhHvVBlQfzlbeReZZ1wC5'
    }
  },
  async mounted () {
    await MP(this.ak);
  },
  watch: {
    $route: {
      handler (newValue) {
        document.title = projectConfig.projectName;
        if (newValue.meta && newValue.meta.title) document.title += ' - ' + newValue.meta.title;
      },
      immediate: true
    }
  }
} 
</script>
